home *** CD-ROM | disk | FTP | other *** search
/ Champak 123 / (Vol 123) Jan 13 2011.iso / Games / moon_patrol.swf / scripts / frame_25 / PlaceObject2_75_12 / CLIPACTIONRECORD onClipEvent(enterFrame).as next >
Text File  |  2011-01-13  |  1KB  |  53 lines

  1. onClipEvent(enterFrame){
  2.    setProperty(this, _X, _X + richtung);
  3.    if(0 < richtung and 650 < _X)
  4.    {
  5.       removeMovieClip(_parent._name);
  6.    }
  7.    if(richtung < 0 and _X < -50)
  8.    {
  9.       removeMovieClip(_parent._name);
  10.    }
  11.    i = 21;
  12.    while(i < 32)
  13.    {
  14.       if(this.hittest(eval("_parent.patrolshot2" + i)) and _name ne "hubschrauber")
  15.       {
  16.          if(_currentframe < 10)
  17.          {
  18.             removeMovieClip("_parent.patrolshot2" + i);
  19.             gotoAndPlay(10);
  20.          }
  21.          if(_currentframe == 30)
  22.          {
  23.             removeMovieClip("_parent.patrolshot2" + i);
  24.             gotoAndPlay(31);
  25.          }
  26.       }
  27.       i++;
  28.    }
  29.    if(getProperty(_parent.patrol, _X) < _X + 5 and _X - 5 < getProperty(_parent.patrol, _X) and _name ne "hubschrauber" and shotable ne "no" and hasshot)
  30.    {
  31.       hasshot = false;
  32.       _root.hubshotsound.start(0,1);
  33.       _parent.hubshot.duplicateMovieClip("hubshot" + _parent.e,_parent.e);
  34.       removeMovieClip("_parent.hubshot" + (_parent.e + 1));
  35.       setProperty("_parent.hubshot" + _parent.e, _X, _X);
  36.       setProperty("_parent.hubshot" + _parent.e, _Y, _Y + 10);
  37.       _parent.e = _parent.e + 1;
  38.    }
  39.    if(222 < _parent.e)
  40.    {
  41.       _parent.e = 200;
  42.    }
  43.    if(_currentframe >= 50)
  44.    {
  45.       if(this.hittest(_parent.patrol))
  46.       {
  47.          _root.scroll = false;
  48.          _root.gotoAndStop(35);
  49.          _root.patrol.gotoAndStop(13);
  50.       }
  51.    }
  52. }
  53.